<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Vue.js</title>
    <link rel="stylesheet" href="style.css">
    <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>

</head>

<body>
    <!-- vue-app是根容器 -->
    <div id="vue-app">
        <h1>动态css class</h1>
        <!-- <h2 :class="{red:true,blue:true}">示例1</h2> -->
        <h2>示例1</h2>
        <!-- <div :class="{changeColor:changeColor}" @click="changeColor=!changeColor">
            <span>Henry</span>
        </div> -->
        <h2>示例2</h2>
        <button @click="changeColor=!changeColor">changeColor</button>
        <button @click="changeLength=!changeLength">changeLength</button>
        <div :class="compClasses">
            <span>Henry</span>
        </div>
    </div>
    <script src="app6.js"></script>
</body>

</html>